﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace Alma
{
    public class BreadcrumbHandler
    {
        public struct Item
        {
            public string Title;
            public string Action;
            public string Controller;
            public object Values;
        }

        public List<Item> Items { get; private set; }

        public BreadcrumbHandler()
        {
            Items = new List<Item>();
        }

        public void Enter(string title, string action, string controller, object values = null)
        {
            Items.Add(new Item()
                          {
                              Title = title,
                              Action = action,
                              Controller = controller,
                              Values = values
                          });
        }

        public void Enter(string title)
        {
            Items.Add(new Item()
                          {
                              Title = title,
                          });
        }
    }
}
